package com.butuh.uang.tuh.ang.model;

import android.os.Parcel;
import android.os.Parcelable;

import java.util.List;

public class BeannerResult extends BaseResult implements Parcelable {

    Data  body;

    public Data getBody() {
        return body;
    }

    public void setBody(Data body) {
        this.body = body;
    }

    @Override
    public String toString() {
        return "BeannerResult{" +
                "body=" + body +
                '}';
    }



    public class Data implements Parcelable {
        /**
         * Head : 2
         * pageFrame : 1
         * datum : [{"ext0":"https://app.appsflyer.com/com.ktakilat.loan?af_siteid=596_2&af_prt=vfineads&pid=vfine_int&c=vfineads&af_click_lookback=7d&clickid={click_id}","titleImg01":"https://resource-storage-file.oss-ap-southeast-5.aliyuncs.com/images/20200904/82f07dcdb1fe08d1519944313b5a52e9.png"},{"ext0":"https://play.google.com/store/apps/details?id=cgso.rscu.zxh&referrer=utm_source%3DUVw53Emj","titleImg01":"https://resource-storage-file.oss-ap-southeast-5.aliyuncs.com/images/20200904/2627514312b2317335ecf54b1bbcd290.png"}]
         */

        private int Head;
        private int pageFrame;
        private List<DatumBean> datum;

        public int getHead() {
            return Head;
        }

        public void setHead(int Head) {
            this.Head = Head;
        }

        public int getPageFrame() {
            return pageFrame;
        }

        public void setPageFrame(int pageFrame) {
            this.pageFrame = pageFrame;
        }

        public List<DatumBean> getDatum() {
            return datum;
        }

        public void setDatum(List<DatumBean> datum) {
            this.datum = datum;
        }

        @Override
        public String toString() {
            return "Data{" +
                    "Head=" + Head +
                    ", pageFrame=" + pageFrame +
                    ", datum=" + datum +
                    '}';
        }


        @Override
        public int describeContents() {
            return 0;
        }

        @Override
        public void writeToParcel(Parcel dest, int flags) {
            dest.writeInt(this.Head);
            dest.writeInt(this.pageFrame);
            dest.writeTypedList(this.datum);
        }

        public Data() {
        }

        protected Data(Parcel in) {
            this.Head = in.readInt();
            this.pageFrame = in.readInt();
            this.datum = in.createTypedArrayList(DatumBean.CREATOR);
        }

        public  final Parcelable.Creator<Data> CREATOR = new Parcelable.Creator<Data>() {
            @Override
            public Data createFromParcel(Parcel source) {
                return new Data(source);
            }

            @Override
            public Data[] newArray(int size) {
                return new Data[size];
            }
        };
    }


    public static class DatumBean implements Parcelable {
        /**
         * ext0 : https://app.appsflyer.com/com.ktakilat.loan?af_siteid=596_2&af_prt=vfineads&pid=vfine_int&c=vfineads&af_click_lookback=7d&clickid={click_id}
         * titleImg01 : https://resource-storage-file.oss-ap-southeast-5.aliyuncs.com/images/20200904/82f07dcdb1fe08d1519944313b5a52e9.png
         */

        private String ext0;
        private String titleImg01;

        public String getExt0() {
            return ext0;
        }

        public void setExt0(String ext0) {
            this.ext0 = ext0;
        }

        public String getTitleImg01() {
            return titleImg01;
        }

        public void setTitleImg01(String titleImg01) {
            this.titleImg01 = titleImg01;
        }

        @Override
        public String toString() {
            return "DatumBean{" +
                    "ext0='" + ext0 + '\'' +
                    ", titleImg01='" + titleImg01 + '\'' +
                    '}';
        }


        @Override
        public int describeContents() {
            return 0;
        }

        @Override
        public void writeToParcel(Parcel dest, int flags) {
            dest.writeString(this.ext0);
            dest.writeString(this.titleImg01);
        }

        public DatumBean() {
        }

        protected DatumBean(Parcel in) {
            this.ext0 = in.readString();
            this.titleImg01 = in.readString();
        }

        public static final Parcelable.Creator<DatumBean> CREATOR = new Parcelable.Creator<DatumBean>() {
            @Override
            public DatumBean createFromParcel(Parcel source) {
                return new DatumBean(source);
            }

            @Override
            public DatumBean[] newArray(int size) {
                return new DatumBean[size];
            }
        };
    }


    @Override
    public int describeContents() {
        return 0;
    }

    @Override
    public void writeToParcel(Parcel dest, int flags) {
        dest.writeParcelable(this.body, flags);
    }

    public BeannerResult() {
    }

    protected BeannerResult(Parcel in) {
        this.body = in.readParcelable(Data.class.getClassLoader());
    }

    public static final Parcelable.Creator<BeannerResult> CREATOR = new Parcelable.Creator<BeannerResult>() {
        @Override
        public BeannerResult createFromParcel(Parcel source) {
            return new BeannerResult(source);
        }

        @Override
        public BeannerResult[] newArray(int size) {
            return new BeannerResult[size];
        }
    };
}
